// src/full-import.ts
// 全量导入，用于CDN方式使用
import * as components from './index';

// 定义组件类型
type ComponentType = {
  new (...args: any[]): HTMLElement;
};

// 注册所有组件（CDN方式使用）
export function registerZssLitUi() {
  const comps = components as unknown as Record<string, ComponentType>;
  
  Object.keys(comps).forEach(key => {
    const Component = comps[key];
    if (typeof Component === 'function' && Component.prototype instanceof HTMLElement) {
      // Component registered
    }
  });
}

// 按需引入的组件导出
export * from './components/basic';
export * from './components/form';
export * from './components/data';
export * from './components/navigation';
export * from './components/feedback';

export default {
  ...components,
  registerZssLitUi
};